| Conditions | 1 |
| Paths | 1 |
| Total Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | 'use strict'; |
||
| 28 | self.update = function() { |
||
| 29 | // do the update in a copy |
||
| 30 | playerCopy = angular.copy(state.player); |
||
| 31 | achievement.checkAchievements(playerCopy); |
||
| 32 | |||
| 33 | state.update(playerCopy); |
||
| 34 | |||
| 35 | // and update all at once |
||
| 36 | state.player = playerCopy; |
||
| 37 | |||
| 38 | $timeout(self.update, 1); |
||
| 39 | }; |
||
| 40 | |||
| 55 |